package com.example.forum.util;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;


@Data
@AllArgsConstructor
@NoArgsConstructor
@ToString
public class JsonResult<T> {
    private String code;
    private T data;
    private String message;

    public JsonResult(String code,String message){
        this.code=code;
        this.message=message;
    }
    public JsonResult(String code,T data){
        this.code="SUCCESS";
        this.data=data;
    }


}
